Skip to content

feat: add OpenClaw agent integration#1861

Open
AIstar007 wants to merge 9 commits intogithub:mainfrom
AIstar007:main
Open

feat: add OpenClaw agent integration#1861
AIstar007 wants to merge 9 commits intogithub:mainfrom
AIstar007:main

Conversation

@AIstar007
Copy link

Description

Adds full support for [OpenClaw](https://openclaw.ai) as a new AI agent in Specify CLI.

OpenClaw is a persistent AI agent daemon that connects to messaging platforms (Telegram, WhatsApp, Slack, etc.) and uses a skill-based architecture — skills are discovered as directories containing a SKILL.md file under <workspace>/skills/, identical to the pattern used by Kimi Code.

Files changed:

  • src/specify_cli/__init__.py — Added "openclaw" to AGENT_CONFIG with folder: ".openclaw/", commands_subdir: "skills", requires_cli: True, install_url: "https://openclaw.ai". Help text updates automatically via _build_ai_assistant_help().
  • .github/workflows/scripts/create-release-packages.sh — Added openclaw to ALL_AGENTS and new create_openclaw_skills() function that generates .openclaw/skills/speckit-<command>/SKILL.md files with OpenClaw-compatible frontmatter.
  • .github/workflows/scripts/create-release-packages.ps1 — Mirror of bash changes: New-OpenClawSkills function, 'openclaw' case in Build-Variant, 'openclaw' added to $AllAgents.
  • scripts/bash/update-agent-context.sh — Added OPENCLAW_FILE="$AGENTS_FILE" (OpenClaw reads AGENTS.md from workspace root, same as amp, kiro-cli, bob), added openclaw) case in update_specific_agent() and update_if_new call in update_all_existing_agents().
  • AGENTS.md — Added OpenClaw to supported agents table, CLI-based agents list, Markdown format section, and directory conventions.
  • README.md — Added OpenClaw to supported agents table, --ai option description, specify check tools list, and examples section.
  • templates/SKILL.md — New workspace-level skill manifest copied to .openclaw/skills/speckit/SKILL.md on specify init --ai openclaw --ai-skills.
  • templates/skill-file-template.md — New per-command SKILL.md template used by install_ai_skills(), following the existing *-template.md naming convention.

Key design decisions:

  • --ai-skills is the primary path for OpenClaw since it uses skill directories, not flat slash command files
  • Skill naming uses dash separator (speckit-specify) vs Kimi Code's dot separator (speckit.specify)
  • OPENCLAW_FILE points to AGENTS.md — the OpenClaw equivalent of CLAUDE.md for Claude Code
  • generic remains last in all agent arrays

Testing

  • Tested locally with uv run specify --help
  • Ran existing tests with uv sync && uv run pytest
  • Tested with a sample project (if applicable)
# openclaw appears in --ai help text
uv run specify init --help

# correct .openclaw/skills/ structure is generated
uv run specify init /tmp/test-openclaw --ai openclaw --ai-skills

# openclaw shows in tool check
uv run specify check

# release package builds correctly
AGENTS=openclaw SCRIPTS=sh .github/workflows/scripts/create-release-packages.sh v0.0.0-test

AI Disclosure

  • I did not use AI assistance for this contribution
  • I did use AI assistance (describe below)

Implementation approach and file structure were developed with AI assistance (Claude). All code was manually reviewed, tested end-to-end, and verified against existing agent integration patterns before submission.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds OpenClaw as a first-class AI agent option in Specify CLI, updating agent configuration, release packaging, context update scripts, and user-facing docs so projects can be initialized with .openclaw/ structures.

Changes:

  • Added openclaw to runtime agent configuration and documentation (README/AGENTS).
  • Extended release package generators (bash + PowerShell) to build OpenClaw skill-directory layouts.
  • Updated agent-context update script to recognize openclaw and map it to AGENTS.md.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/specify_cli/__init__.py Registers openclaw in AGENT_CONFIG (folder + skills subdir + CLI requirement).
templates/skill-file-template.md Adds a new SKILL.md template file (currently not referenced by code).
templates/commands/skill.md Introduces a new template under templates/commands/ intended as a “Speckit skill” description.
scripts/bash/update-agent-context.sh Adds openclaw option and maps it to AGENTS.md.
.github/workflows/scripts/create-release-packages.sh Adds openclaw build variant and generates .openclaw/skills/<skill>/SKILL.md directories.
.github/workflows/scripts/create-release-packages.ps1 PowerShell mirror of OpenClaw release packaging support.
README.md Documents OpenClaw support, --ai openclaw, and tool checks.
AGENTS.md Documents OpenClaw directory conventions and configuration fields.
Comments suppressed due to low confidence (1)

templates/commands/skill.md:4

  • PR description mentions a new templates/SKILL.md copied to .openclaw/skills/speckit/SKILL.md, but the added file here is templates/commands/skill.md (which will be packaged/installed as a normal command template). If the intent is a workspace-level OpenClaw skill manifest, it likely shouldn’t live under templates/commands/.
---
name: "speckit"
description: "Full Spec-Driven Development (SDD) workflow powered by github/spec-kit. Use speckit-specify to start a feature, then speckit-plan, speckit-tasks, and speckit-implement in sequence."
metadata:

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +2 to +7
name: "speckit"
description: "Full Spec-Driven Development (SDD) workflow powered by github/spec-kit. Use speckit-specify to start a feature, then speckit-plan, speckit-tasks, and speckit-implement in sequence."
metadata:
author: "github-spec-kit"
source: "https://github.com/github/spec-kit"
version: "1.0.0"
Comment on lines +1 to +12
---
name: "{SKILL_NAME}"
description: "{DESCRIPTION}"
compatibility: "Requires spec-kit project structure with .specify/ directory"
metadata:
author: "github-spec-kit"
source: "templates/commands/{COMMAND_NAME}.md"
---

# Spec Kit {COMMAND_TITLE} Skill

{COMMAND_BODY}
Comment on lines +76 to +77
# AMP, Kiro CLI, IBM Bob, and OpenClaw all share AGENTS.md — use AGENTS_FILE to
# avoid updating the same file multiple times.
Copy link
Collaborator

@mnriem mnriem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address Copilot feedback. If not applicable, please explain why

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants